Various communication systems transmit packets from a first node (the transmitting node) to a second node (the receiving node) over a communication channel. The transmitting node typically includes an encoder and a transmitter, and the receiving node typically includes a detector and a decoder. In many communication systems, the packets are encoded utilizing line-codes, which are configured to suit the characteristics of the channel, and facilitate the operation of the detector. For example, line-codes characterized by high transition density facilitate better clock recovery. As another example, line-codes characterized by good DC-balance, usually indicated by low running disparity, are better suitable for communication channels with poor response to DC signals. DC-balanced line-codes also facilitate simpler coupling of the nodes to the communication channel (e.g. AC coupling rather than DC coupling).
In many communication systems, idle signals are transmitted during the gaps between packets. The duration of the gap between the packets may be unknown in advance, and the receiving node needs to determine the starting point of the following packet by identifying the end of the idle signal. Since the idle signals are utilized by the receiving node in order to maintain synchronization, the idle signals are usually configured to comply with the line-code related characteristics, such as running disparity and transition density.